I don't know the exact details, but remember that both of those things (super-injunctions and ASBOs) are only possible because of Acts of Parliament making them possible. Parliament writes the laws (proposed by an MP/group of MPs, voted on by the Commons, if passed then voted on by the Lords, optional back and forth if the Lords reject it and amendments are made, finally either passed or canned), the courts enforce them.
Also, super-injunctions do more than your example; they prevent absolutely anyone from discussing the injunction, including the fact that the injunction exists.
ASBOs (Anti-Social Behaviour Orders) are meant to deal with people who are being a nuisance, but not technically breaking a specific law, or breaking a minor one repeatedly in such a way as to cause a nuisance. E.g. someone may be regularly getting drunk, shouting at passersby and pissing in the street. Nothing they can be locked up for necessarily, but you don't want them doing it either and causing distress, so you have the option of giving them an ASBO preventing them from, say, being drunk in public. If they breach the ASBO, that potentially carries a jail term. In practice however there is a perception in some quarters that they're handed out like candy, sometimes for things that people can't realistically be expected to comply with (you can't expect an alcoholic to be sober in public - they need help, not an ABSO, etc) and poorly enforced (the prisons are too full to jail every petty ASBO-breaker).